Skip to content

Normalize productinfo updater versions to 3 components before comparison#4470

Merged
Marc-André Moreau (mamoreau-devolutions) merged 2 commits intomainfrom
copilot/accept-version-with-four-parts
Mar 14, 2026
Merged

Normalize productinfo updater versions to 3 components before comparison#4470
Marc-André Moreau (mamoreau-devolutions) merged 2 commits intomainfrom
copilot/accept-version-with-four-parts

Conversation

Copy link
Contributor

Copilot AI commented Mar 14, 2026

The productinfo-based updater was treating 2026.1.0 and 2026.1.0.0 as different versions, which caused repeated prompts to install the already-installed release. This change trims any parsed 4-part productinfo version to its first 3 components before comparing it with the installed version.

  • Updater comparison

    • Normalize parsed System.Version values from the productinfo path before evaluating available > current.
    • Treat any 4-part version as its 3-part equivalent for comparison:
      • 2026.1.0.02026.1.0
      • 2026.1.0.52026.1.0
  • Normalization helper

    • Add a shared helper to collapse 4-part versions to 3 parts without changing 2-part or 3-part versions.
    • Keep parse-fallback behavior unchanged so unrelated fallback logic continues using its existing version shape.
  • Regression coverage

    • Add focused unit coverage for the normalization behavior to lock in the comparison contract for:
      • 2-part versions
      • 3-part versions
      • 4-part versions with zero revision
      • 4-part versions with non-zero revision
CoreTools.NormalizeVersionForComparison(new Version("2026.1.0.0")); // 2026.1.0
CoreTools.NormalizeVersionForComparison(new Version("2026.1.0.5")); // 2026.1.0

Warning

Firewall rules blocked me from connecting to one or more addresses (expand for details)

I tried to connect to the following addresses, but was blocked by firewall rules:

  • crl.godaddy.com
    • Triggering command: /usr/bin/dotnet dotnet restore --no-dependencies /tmp/codeql-scratch-1c162a69c27bc0ce/dbs/csharp/working/EB23B7D1B15B85081672081E55C17E18/missingpackages_workingdir --packages /tmp/codeql-scratch-1c162a69c27bc0ce/dbs/csharp/working/missingpackages /p:DisableImplicitNuGetFallbackFolder=true --verbosity normal --configfile /tmp/codeql-scratch-1c162a69c27bc0ce/dbs/csharp/working/nugetconfig/nuget.config --force (dns block)
  • invalid.url.com
    • Triggering command: /usr/share/dotnet/dotnet /usr/share/dotnet/dotnet exec --runtimeconfig /home/REDACTED/work/UniGetUI/UniGetUI/src/UniGetUI.Core.Tools.Tests/bin/x64/Debug/net8.0/UniGetUI.Core.Tools.Tests.runtimeconfig.json --depsfile /home/REDACTED/work/UniGetUI/UniGetUI/src/UniGetUI.Core.Tools.Tests/bin/x64/Debug/net8.0/UniGetUI.Core.Tools.Tests.deps.json /home/REDACTED/work/UniGetUI/UniGetUI/src/UniGetUI.Core.Tools.Tests/bin/x64/Debug/net8.0/testhost.dll --port 32923 --endpoint 127.0.0.1:032923 --role client --parentprocessid 4613 --telemetryoptedin false (dns block)
    • Triggering command: /usr/share/dotnet/dotnet /usr/share/dotnet/dotnet exec --runtimeconfig /home/REDACTED/work/UniGetUI/UniGetUI/src/UniGetUI.Core.Tools.Tests/bin/Debug/net8.0/UniGetUI.Core.Tools.Tests.runtimeconfig.json --depsfile /home/REDACTED/work/UniGetUI/UniGetUI/src/UniGetUI.Core.Tools.Tests/bin/Debug/net8.0/UniGetUI.Core.Tools.Tests.deps.json /home/REDACTED/work/UniGetUI/UniGetUI/src/UniGetUI.Core.Tools.Tests/bin/Debug/net8.0/testhost.dll --port 37149 --endpoint 127.0.0.1:037149 --role client --parentprocessid 5024 --telemetryoptedin false (dns block)
    • Triggering command: /usr/share/dotnet/dotnet /usr/share/dotnet/dotnet exec --runtimeconfig /home/REDACTED/work/UniGetUI/UniGetUI/src/UniGetUI.Core.Tools.Tests/bin/Debug/net8.0/UniGetUI.Core.Tools.Tests.runtimeconfig.json --depsfile /home/REDACTED/work/UniGetUI/UniGetUI/src/UniGetUI.Core.Tools.Tests/bin/Debug/net8.0/UniGetUI.Core.Tools.Tests.deps.json /home/REDACTED/work/UniGetUI/UniGetUI/src/UniGetUI.Core.Tools.Tests/bin/Debug/net8.0/testhost.dll --port 44187 --endpoint 127.0.0.1:044187 --role client --parentprocessid 5246 --telemetryoptedin false son (dns block)
  • marticliment.com
    • Triggering command: /usr/share/dotnet/dotnet /usr/share/dotnet/dotnet exec --runtimeconfig /home/REDACTED/work/UniGetUI/UniGetUI/src/UniGetUI.Core.Tools.Tests/bin/x64/Debug/net8.0/UniGetUI.Core.Tools.Tests.runtimeconfig.json --depsfile /home/REDACTED/work/UniGetUI/UniGetUI/src/UniGetUI.Core.Tools.Tests/bin/x64/Debug/net8.0/UniGetUI.Core.Tools.Tests.deps.json /home/REDACTED/work/UniGetUI/UniGetUI/src/UniGetUI.Core.Tools.Tests/bin/x64/Debug/net8.0/testhost.dll --port 32923 --endpoint 127.0.0.1:032923 --role client --parentprocessid 4613 --telemetryoptedin false (dns block)
    • Triggering command: /usr/share/dotnet/dotnet /usr/share/dotnet/dotnet exec --runtimeconfig /home/REDACTED/work/UniGetUI/UniGetUI/src/UniGetUI.Core.IconEngine.Tests/bin/x64/Debug/net8.0/UniGetUI.Core.IconEngine.Tests.runtimeconfig.json --depsfile /home/REDACTED/work/UniGetUI/UniGetUI/src/UniGetUI.Core.IconEngine.Tests/bin/x64/Debug/net8.0/UniGetUI.Core.IconEngine.Tests.deps.json /home/REDACTED/work/UniGetUI/UniGetUI/src/UniGetUI.Core.IconEngine.Tests/bin/x64/Debug/net8.0/testhost.dll --port 33247 --endpoint 127.0.0.1:033247 --role client --parentprocessid 4649 --telemetryoptedin false (dns block)
    • Triggering command: /usr/share/dotnet/dotnet /usr/share/dotnet/dotnet exec --runtimeconfig /home/REDACTED/work/UniGetUI/UniGetUI/src/UniGetUI.Core.Tools.Tests/bin/Debug/net8.0/UniGetUI.Core.Tools.Tests.runtimeconfig.json --depsfile /home/REDACTED/work/UniGetUI/UniGetUI/src/UniGetUI.Core.Tools.Tests/bin/Debug/net8.0/UniGetUI.Core.Tools.Tests.deps.json /home/REDACTED/work/UniGetUI/UniGetUI/src/UniGetUI.Core.Tools.Tests/bin/Debug/net8.0/testhost.dll --port 37149 --endpoint 127.0.0.1:037149 --role client --parentprocessid 5024 --telemetryoptedin false (dns block)
  • ocsp.godaddy.com
    • Triggering command: /usr/bin/dotnet dotnet restore --no-dependencies /tmp/codeql-scratch-1c162a69c27bc0ce/dbs/csharp/working/EB23B7D1B15B85081672081E55C17E18/missingpackages_workingdir --packages /tmp/codeql-scratch-1c162a69c27bc0ce/dbs/csharp/working/missingpackages /p:DisableImplicitNuGetFallbackFolder=true --verbosity normal --configfile /tmp/codeql-scratch-1c162a69c27bc0ce/dbs/csharp/working/nugetconfig/nuget.config --force (dns block)

If you need me to access, download, or install something from one of these locations, you can either:


💬 Send tasks to Copilot coding agent from Slack and Teams to turn conversations into code. Copilot posts an update in your thread when it's finished.

Co-authored-by: mamoreau-devolutions <242016029+mamoreau-devolutions@users.noreply.github.com>
Copilot AI changed the title [WIP] Update version comparison logic for product info Normalize productinfo updater versions to 3 components before comparison Mar 14, 2026
@mamoreau-devolutions Marc-André Moreau (mamoreau-devolutions) marked this pull request as ready for review March 14, 2026 04:15
@mamoreau-devolutions Marc-André Moreau (mamoreau-devolutions) merged commit c2e8590 into main Mar 14, 2026
1 check passed
@mamoreau-devolutions Marc-André Moreau (mamoreau-devolutions) deleted the copilot/accept-version-with-four-parts branch March 14, 2026 11:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

3 participants